#!/usr/bin/env python
# -*- coding: utf-8 -*-
# datetime: 4/12/2023 下午10:54
# Author: name
# File: debugs.py
# ide: PyCharm
# description:
result=None
code = '''
import random
import string
def generate_random_string(length):
    letters = string.ascii_letters
    result = ''.join(random.choice(letters) for _ in range(length))
    return result
'''

exec(code, globals())
# globals()['length'] = 100
exec('result=generate_random_string(100)', globals())
print(result)